<!DOCTYPE html>
<html lang="en">

<head>
   <meta charset="UTF-8">
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   <meta http-equiv="X-UA-Compatible" content="ie=edge">
   <title>织蝶云 - OA+PM+CRM一站式企业应用管理平台</title>
   <!-- 小图标 -->
   <link rel="shortcut icon" href="./images/favicon/favicon.ico" type="image/x-icon">
   <!-- 清除样式 -->
   <link rel="stylesheet" href="./css/resets.css">
   <!-- bootstrap的css包 -->
   <link rel="stylesheet" href="./lib/bootstrap_4/css/bootstrap.min.css">
   <!-- 模板样式css -->
   <link rel="stylesheet" href="./css/template.css">
   <link rel="stylesheet" href="./css/gy_userAdd.css">
   <!-- 清除样式 -->
   <link rel="stylesheet" href="./css/gy_resets.css">
   <!-- 引入字体图标css -->
   <link rel="stylesheet" href="./css/iconfont/lyd_approval/iconfont.css">
   <link rel="stylesheet" href="./css/iconfont/gy_iconfont/iconfont.css">

</head>

<body>
   <div class="left_nav">
      <div class="logo">
         <a href="/tmeplate">
            <img src="./images/lyd/lyd_approval_frame_logo-left.png" alt="织蝶云">
         </a>
      </div>
      <div class="left_nav_menu">
         <ul class="left_nav_menu_nav">
            <li class="btn-block">
               <a href="/page">
                  <i class="iconfont icon-home"></i>
                  <span>主页</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="/mange">
                  <i class="iconfont icon-list"></i>
                  <span>项目</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="/lyd_approval">
                  <i class="iconfont icon-suitcase"></i>
                  <span>审批</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="/gy-CRM">
                  <i class="iconfont icon-users"></i>
                  <span>CRM</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="javascript:;">
                  <i class="iconfont icon-calendar"></i>
                  <span>日程</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="javascript:;">
                  <i class="iconfont icon-tasks"></i>
                  <span>报告</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="/lyj_knowledge">
                  <i class="iconfont icon-book"></i>
                  <span>知识</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="/document">
                  <i class="iconfont icon-columns"></i>
                  <span>文档</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="/resume">
                  <i class="iconfont icon-male"></i>
                  <span>简历</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="javascript:;">
                  <i class="iconfont icon-tupian"></i>
                  <span>相册</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="javascript:;">
                  <i class="iconfont icon-bull-horn-announcer"></i>
                  <span>公告</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="javascript:;">
                  <i class="iconfont icon-gavel"></i>
                  <span>考勤</span>
               </a>
            </li>
            <li class="btn-block">
               <a href="/yyl_system">
                  <i class="iconfont icon-cogs"></i>
                  <span>系统</span>
               </a>
            </li>
         </ul>
      </div>
   </div>
   <div class="top_nav_box">
      <div class="top_nav">
         <a class="toggle-btn">
            <i class="iconfont icon-bars"></i>
         </a>
         <div class="top_center">
            <a href="javascript:;" class="btn btn-all actives">客户</a>
            <a href="javascript:;" class="btn btn-all">任务</a>
            <a href="javascript:;" class="btn btn-all">公海</a>
            <a href="javascript:;" class="btn btn-all">线索</a>
            <a href="javascript:;" class="btn btn-all">商机</a>
            <a href="javascript:;" class="btn btn-all">合同</a>
            <a href="javascript:;" class="btn btn-all">产品</a>
            <a href="javascript:;" class="btn btn-all">售后</a>
            <a href="javascript:;" class="btn btn-all">目标</a>
            <a href="javascript:;" class="btn btn-all">统计</a>
         </div>
         <div class="top_right">
            <ul class="top_right_info">
               <li>
                  <a href="javascript:;" class="btn info_icon">
                     <i class="iconfont icon-envelope-o"></i>
                  </a>
                  <!-- 管理内容 -->
                  <div class="nav_switch_off">
                     <h5>你有0条信息</h5>
                     <ul>
                        <li>目前还没有最新消息</li>
                        <li>
                           <a href="javascript:;">查看更多</a>
                        </li>
                     </ul>
                  </div>
               </li>
               <li>
                  <a href="javascript:;" class="admi">
                     <img src="./images/lyd/6.jpg" alt="管理员">
                     管理员
                     <span class="iconfont icon-caret-bottom"></span>
                  </a>
                  <ul class="nav_switch_no amid_menu nav_switch_off">
                     <li><a href="javascript:;"><i class="iconfont icon-user"></i>个人主页</a></li>
                     <li><a href="javascript:;"><i class="iconfont icon-cog"></i>基本资料</a></li>
                     <li><a href="javascript:;"><i class="iconfont icon-camera"></i>更换头像</a></li>
                     <li><a href="javascript:;"><i class="iconfont icon-cog"></i>更换密码</a></li>
                     <li><a href="javascript:;"><i class="iconfont icon-list"></i>我的任务</a></li>
                     <li><a href="javascript:;"><i class="iconfont icon-magnet"></i>升级为付费版</a></li>
                     <li><a href="javascript:;"><i class="iconfont icon-tasks"></i>订单</a></li>
                     <li><a href="javascript:;"><i class="iconfont icon-comments"></i>聊天</a></li>
                     <li><a href="javascript:;"><i class="iconfont icon-SignOut"></i>退出</a></li>
                  </ul>
               </li>
            </ul>
         </div>
      </div>
      <div class="content-box">
         <div class="content">
            <!-- 添加用户 -->
            <div class="content-add clearfix">
               <!-- 添加用户左边 -->
               <div class="content-add-left">
                  <p><i class="iconfont icon-arrow-circle-o-down"></i>添加客户</p>
               </div>
               <!-- 添加用户右边 -->
               <div class="content-add-right">
                  <a href="/gy-CRM"> <button><i class="iconfont icon-chevronleft"></i>返回</button></a>
               </div>
            </div>
            <!-- 添加用户列表 -->
            <div class="content-add-liebiao">
               <div class="content-add-liebiao-top">
                  <div class="content-add-liebiao-top-one">
                     <form action="" class="user-add">
                        <div class="content-add-liebiao-top-one-top">
                           <P>企业信息</P>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              <span>*</span>
                              客户类型
                           </div>
                           <div class="form-col2">
                              <input type="radio" value="1" name="type" checked>企业
                              <input type="radio" value="2" name="type">个人
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col qiyegy">
                           <div class="form-col1 ">
                              <span>*</span>
                              企业名称
                           </div>
                           <div class="form-col3">
                              <input type="text" name="name" id="" placeholder="企业名称" value="<%= gy_clientsCompany %>">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              行业
                           </div>
                           <div class="form-col4">
                              <select name="hangye" id="">
                                 <option value="">请选择一级行业</option>
                                 <option value="78">IT行业</option>
                                 <option value="79">金融行业</option>
                                 <option value="80">专业服务</option>
                                 <option value="81">教育/培训行业</option>
                                 <option value="82">消费品行业</option>
                                 <option value="83">文化传媒行业</option>
                                 <option value="84">建筑/房地产行业</option>
                                 <option value="85">贸易物流行业</option>
                                 <option value="86">制造工业</option>
                                 <option value="87">医疗/卫生</option>
                                 <option value="88">服务业</option>
                                 <option value="89">其他</option>
                              </select>
                              <select name="hangye1" id="">
                                 <option value="">请选择二级行业</option>
                                 <option value="78">IT行业</option>
                                 <option value="79">金融行业</option>
                                 <option value="80">专业服务</option>
                                 <option value="81">教育/培训行业</option>
                                 <option value="82">消费品行业</option>
                                 <option value="83">文化传媒行业</option>
                                 <option value="84">建筑/房地产行业</option>
                                 <option value="85">贸易物流行业</option>
                                 <option value="86">制造工业</option>
                                 <option value="87">医疗/卫生</option>
                                 <option value="88">服务业</option>
                                 <option value="89">其他</option>
                              </select>

                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              企业规模
                           </div>
                           <div class="form-col3">
                              <select name="scale">
                                 <option value="">选择企业规模</option>
                                 <option value="1">0-10人</option>
                                 <option value="2">10-50人</option>
                                 <option value="3">50-100人</option>
                                 <option value="4">100-1000人</option>
                                 <option value="5">1000以上</option>
                              </select>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              公司邮箱
                           </div>
                           <div class="form-col3">
                              <input type="email" name="email" id="" placeholder="公司邮箱">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              座机
                           </div>
                           <div class="form-col3">
                              <input type="text" name="special" id="" placeholder="座机">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              传真
                           </div>
                           <div class="form-col3">
                              <input type="text" name="faxes" id="" placeholder="传真号">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              网址
                           </div>
                           <div class="form-col3">
                              <input type="url" name="url" id="" placeholder="http://">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              省市
                           </div>
                           <div class="form-col4">
                              <select name="sengfen" id="">
                                 <option value="">请选择省/直辖市</option>
                                 <option value="1">北京</option>
                                 <option value="2">天津</option>
                                 <option value="3">河北</option>
                                 <option value="4">山西</option>
                                 <option value="5">内蒙古</option>
                                 <option value="6">辽宁</option>
                                 <option value="7">吉林</option>
                                 <option value="8">黑龙江</option>
                                 <option value="9">上海</option>
                                 <option value="10">江苏</option>
                                 <option value="11">浙江</option>
                                 <option value="12">安徽</option>
                                 <option value="13">福建</option>
                                 <option value="14">江西</option>
                                 <option value="15">山东</option>
                                 <option value="16">河南</option>
                                 <option value="17">湖北</option>
                                 <option value="18">湖南</option>
                                 <option value="19">广东</option>
                                 <option value="20">广西</option>
                                 <option value="21">海南</option>
                                 <option value="22">重庆</option>
                                 <option value="23">四川</option>
                                 <option value="24">贵州</option>
                                 <option value="25">云南</option>
                                 <option value="26">西藏</option>
                                 <option value="27">陕西</option>
                                 <option value="28">甘肃</option>
                                 <option value="29">青海</option>
                                 <option value="30">宁夏</option>
                                 <option value="31">新疆</option>
                                 <option value="32">台湾</option>
                                 <option value="33">香港</option>
                                 <option value="34">澳门</option>
                                 <option value="35">海外</option>
                                 <option value="36">其他</option>
                              </select>
                              <select name="shengfi" id="">
                                 <option value="">请选择市/地区</option>
                                 <option value="385">成都</option>
                                 <option value="386">自贡</option>
                                 <option value="387">攀枝花</option>
                                 <option value="388">泸州</option>
                                 <option value="389">德阳</option>
                                 <option value="390">绵阳</option>
                                 <option value="391">广元</option>
                                 <option value="392">遂宁</option>
                                 <option value="393">内江</option>
                                 <option value="394">乐山</option>
                                 <option value="395">南充</option>
                                 <option value="396">眉山</option>
                                 <option value="397">宜宾</option>
                                 <option value="398">广安</option>
                                 <option value="399">达州</option>
                                 <option value="400">雅安</option>
                                 <option value="401">巴中</option>
                                 <option value="402">资阳</option>
                                 <option value="403">阿坝</option>
                                 <option value="404">甘孜</option>
                                 <option value="405">凉山</option>
                              </select>

                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              详情地址
                           </div>
                           <div class="form-col3">
                              <input type="text" name="details" id="" placeholder="公司详细地址">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              邮编
                           </div>
                           <div class="form-col3">
                              <input type="text" name="postcode" id="" placeholder="邮政编码">
                           </div>
                        </div>
                        <!-- 客户类型 -->
                        <div class="content-add-liebiao-top-one-top">
                           <P>客户类型</P>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              客户分类
                           </div>
                           <div class="form-col3">
                              <select name="scale1">
                                 <option value="">请选择</option>
                                 <option value="1">储备客户</option>
                                 <option value="2">潜在客户</option>
                                 <option value="3" selected="">意向客户</option>
                                 <option value="4">成交客户</option>
                                 <option value="5">失败客户</option>
                                 <option value="6">已流失客户</option>
                              </select>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              客户级别
                           </div>
                           <div class="form-col3 gyxing">
                              <select name="scale2">
                                 <!-- <option value="">请选择</option> -->
                                 <option value="1">一星</option>
                                 <option value="2">二星</option>
                                 <option value="3">三星</option>
                                 <option value="4">四星</option>
                                 <option value="5">五星</option>
                              </select>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              客户类别
                           </div>
                           <div class="form-col3">
                              <select name="scale3">
                                 <option value="">请选择</option>
                                 <option value="1" selected="">普通客户</option>
                                 <option value="2">VIP客户</option>
                                 <option value="3">老客户</option>
                                 <option value="4">代理商</option>
                                 <option value="5">供货商</option>
                                 <option value="6">合作伙伴</option>
                                 <option value="7">其他</option>
                              </select>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              客户来源
                           </div>
                           <div class="form-col3">
                              <select name="scale4">
                                 <option value="">请选择</option>
                                 <option value="1">行业展会</option>
                                 <option value="2">商务研讨</option>
                                 <option value="3">市场活动</option>
                                 <option value="4">客户介绍</option>
                                 <option value="5">合作伙伴</option>
                                 <option value="6">网络搜索</option>
                                 <option value="7">广告</option>
                                 <option value="8">职员引介</option>
                                 <option value="9">主动获取</option>
                                 <option value="10">其他</option>
                                 <option value="11">线索</option>
                              </select>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              客户成熟度
                           </div>
                           <div class="form-col3">
                              <select name="scale5">
                                 <option value="">请选择</option>
                                 <option value="1">明确成交意向</option>
                                 <option value="2">有初步成交意向</option>
                                 <option value="3">关键人有成交意向</option>
                                 <option value="4">关键人成交意向不确定</option>
                                 <option value="5">初步联系，有意向</option>
                                 <option value="6">初步联系，意向不确定</option>
                                 <option value="7">新建客户</option>
                                 <option value="8">明显拒绝</option>
                                 <option value="9">无效客户</option>
                              </select>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              客户状态
                           </div>
                           <div class="form-col3">
                              <select name="scale6">
                                 <!-- <option value="">请选择</option> -->
                                 <option value="1">新建</option>
                                 <option value="2">跟进中</option>
                                 <option value="3">已签单</option>
                                 <option value="4">重新跟进</option>
                                 <option value="5">已放弃</option>
                                 <option value="6">已搁置</option>
                              </select>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top">
                           <P>主联系人信息</P>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col  gyxingming">
                           <div class="form-col1">
                              <span>*</span>
                              客户姓名
                           </div>
                           <div class="form-col3">
                              <input type="text" name="clientt" id="" placeholder="请填写姓名" value="<%= gy_clientsUsers%>">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              <!-- <span>*</span> -->
                              性别
                           </div>
                           <div class="form-col2">
                              <input type="radio" value="1" name="type" checked>男
                              <input type="radio" value="2" name="type">女
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col sheri">
                           <div class="form-col1">
                              生日
                           </div>
                           <div class="form-col3">
                              <input type="text" name="birthday" id="test1" placeholder="出生日期"
                                 value="<%= new Date(gy_clientsdata).toLocaleString('zh-CN').substring(0,10) %>">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col dianhua">
                           <div class="form-col1">
                              电话
                           </div>
                           <div class="form-col3">
                              <input type="text" name="call" id="" placeholder="电话" value="<%=  gy_clientsPhone%>">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col shouji">
                           <div class="form-col1">
                              <span>*</span>
                              手机
                           </div>
                           <div class="form-col3">
                              <input type="text" name="cellphone" id="" placeholder="请填写手机号"
                                 value="<%=  gy_clientsTelephone%>">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              联系人
                           </div>
                           <div class="form-col3">
                              <input type="text" name="contacts" id="" placeholder="联系人">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              邮编
                           </div>
                           <div class="form-col3">
                              <input type="text" name="postal" id="" placeholder="邮编">
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col1">
                           <div class="form-col1">
                              意向产品
                           </div>
                           <div class="form-col3">
                              <textarea name="intention" id="" placeholder="客户意向产品"></textarea>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col1">
                           <div class="form-col1">
                              客户喜好
                           </div>
                           <div class="form-col3">
                              <textarea name="like " id="" placeholder="客户喜欢什么..."></textarea>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col1">
                           <div class="form-col1">
                              客户备注
                           </div>
                           <div class="form-col3">
                              <textarea name="remark" id="" placeholder="客户备注..."></textarea>
                           </div>
                        </div>
                        <div class="content-add-liebiao-top-one-top-col">
                           <div class="form-col1">
                              <button type="button" class="form-col1-button btn-add" data-id="<%= gy_id%>">提交保存</button>
                           </div>
                           <div class="form-col2">
                              <input type="checkbox" value="1" name="type" class="form-col1-input">继续创建下一个
                           </div>
                        </div>
                     </form>
                  </div>
               </div>
            </div>
            <!-- 底部 -->
            <div>
               <p class="qijing">2020 © by 织蝶云系统 · <a href="">织蝶云手册</a> · <a href="">翌羽信息科技(上海)有限公司 版权所有</a></p>
            </div>
         </div>
      </div>
   </div>



   <!-- 引入jquery -->
   <script src="./lib/jquery/jquery.min.js"></script>
   <!-- 引入bootstrap的js -->
   <script src="./lib/bootstrap_4/js/bootstrap.min.js"></script>
   <!-- 模板样式js -->
   <script src="./js/gy_useradd.js"></script>

   <!-- <script src="./js/template.js"></script> -->

   <!-- 引入字体图标js -->
   <script src="./js/iconfont/lyd_approval/iconfont.js"></script>
   <script src="./js/iconfont/gy_iconfont/iconfont.js"></script>
   <script src="./lib/layDate-v5.0.9/laydate/laydate.js"></script>
   <!-- 时间 -->
   <script type="text/template" id="ce_template">
      <input type="text" name="birthday" id="test1" placeholder="出生日期"
      value="{{gy_clientsdata}}">
   </script>
   <script>
      // 日历插件 
      laydate.render({
         elem: '#test1'
      })
   </script>
   <script>
      $('.btn-add').on('click', function () {
         // console.log(123);
         let str = $('.user-add').serialize()
         let id = $(this).data('id');
         // console.log(datas);

         // console.log($('.qiyegy input').val());
         if ($('.qiyegy input').val() == '') {
            alert('请填写企业名称');
            return;
         } else if ($('.gyxingming input').val() == '') {
            alert('请填写客户姓名');
            return;
         } else if ($('.shouji input').val() == '') {
            alert('请填写手机');
            return;
         } else if ($('.dianhua input').val() == '') {
            alert('请填写电话');
            return;
         } else if ($('.sheri input').val() == '') {
            alert('请填写出生日期');
            return;
         } else {
            $.ajax({
               type: 'post',
               url: '/gy_userupdate',
               data: str + '&id=' + id,
               success: function (data) {
                  // console.log(data);
                  if (data.code == '1007') {
                     alert(data.message);
                     location.href = '/gy-CRM'
                  }
               }
            })
         }

      })

      let datas = function () {
         // let da = ;
         let d = new Date($('#test1').val().toString());
         console.log(d);

         // console.log(da.getFullYear());

         // $.ajax({
         //    type:'get',
         //    url:'/ce',
         //    data:{da,da},
         //    success:function(data){
         //       console.log(data);
         //    }

         // })
      }
      datas()
   </script>
</body>

</html>